<?php 
$testmail       = true;
$SMTPConfig     = gpc_getStringArray('SMTPConfig');

$config_email   = new stdClass();

foreach($SMTPConfig as $k=>$v)
{
    $config_email->$k=$v;
}
//var_dump($config_email);exit;

$subject    = "test mail from ".$titlesite;
$msg        = "This is an e-mail message sent automatically by Admin Manager while testing the settings for your SMTP account.<br>";
$msg       .= "test date: ".date("Y-m-d H:i:s")."<br> Ip:".$ip;
$rs         = send_email($config_email->user,$config_email->name,$subject,$msg);

if($rs)
{
    error_transfer('send email success');
}else
{
    error_transfer($GLOBALS['err']);
}
exit;
?>